<%@page import="model.*"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%
	String user = (String) session.getAttribute("user");
%>
<%
	String m = (((String) request.getAttribute("m")) != null) ? ((String) request
			.getAttribute("m")) : ((String) request.getParameter("m"));
	String r = (((String) request.getAttribute("r")) != null) ? ((String) request
			.getAttribute("r")) : ((String) request.getParameter("r"));
	String rd = null;
	m = (m == null) ? "mg_default" : m;
	r = (r == null) ? "in" : r;
	Message message = new Message();
	Message mg = (message.getMgByName(m) != null) ? message
			.getMgByName(m) : message.getMgByName("mg_default");

	rd = message.reDirect(r);

	User u = new User();
%>
<title>MYFILM - <%=mg.getM_title()%></title>
<META HTTP-EQUIV="Refresh" CONTENT="2; URL=<%=rd%>">
<jsp:include page="include/header.jsp"></jsp:include>
<jsp:include page="include/slide-show.jsp"></jsp:include>
<div id="content-container">
	<jsp:include page="include/sidebar-admin.jsp"></jsp:include>
	<div id="content">
		<%
			if ((user == null) && (m.equals("logout"))) {
		%>
		<center>
			<div
				style="border: 1px solid #cfcfcf; padding: 20px 10px 20px 10px; background-color: #f3f3f3; width: 410px">
				<b>Bạn chưa Đăng Nhập ! </b>
			</div>
		</center>
		<%
			} else if ((user != null) && (m.equals("logout"))) {
				session.removeAttribute("user");
				session.invalidate();
		%>
		<center>
			<div
				style="border: 1px solid #cfcfcf; padding: 20px 10px 20px 10px; background-color: #f3f3f3; width: 410px">
				<b>Đăng Xuất Thành Công<br> <img border=0
					src="css/images/loading.gif" width="32" height="32"><Br></b>
			</div>
		</center>
		<%
			} else if (!m.equals("logout")) {
		%>
		<p class='warning'><%=mg.getM_content()%></p>
		<%
			}
		%>
	</div>
	<!--end content-->
	<jsp:include page="include/footer.jsp"></jsp:include>